<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>
<body style="font-family:Arial, Helvetica, sans-serif">
<?php
ob_flush();
ob_start();
$dayToday = Model_DatetimeHelper::dayToday();

?>
<h1>Shop Daily Summary : <?php echo $this->dateToCheck ?></h1>
<table width="700" border="1" cellspacing="0" cellpadding="5">
  <tr>
    <th rowspan="2" scope="col">Shop</th>
    <th colspan="2" scope="col">Attendance</th>
    <th colspan="3" scope="col">Cash Account</th>
  </tr>
  <tr>
    <th scope="col" >Yesterday</th>
    <th scope="col" >Today</th>
    <th scope="col" >Opening</th>
  </tr>
<?php foreach($this->arrRes as $key => $v){?>    
  <tr>
    <td><?php echo $v[0]?></td>
    <td>Off Duty: <?php echo $v[1]?><br />
	<span style="font-size:12px">
    <?php echo $v[2]?>
    </span>
</td>
    <td>On Duty: <?php echo $v[3]?><br />
	<span style="font-size:12px">
    <?php echo $v[4]?>
    </span>
</td>
    <td align="center" valign="middle"><?php echo $v[13]?></td>
  </tr>
<?php } ?>  
</table>
</body>
<?php
$mailbody = "<html><body> ";
$mailbody .= ob_get_contents();

if($this->auto == true){
	$mail = new Model_Emailshandler();
	$mail->sendNormalEmail('simon.phonecollection@gmail.com;ken@phonecollection.com.au;office@phonecollection.com.au;eco3@phonecollection.com.au',"Shop Open Status", $mailbody);
}
?>
</html>